#pragma once
#include <iostream>

using namespace std;
namespace u33{
	class data
	{
		string ip;
		int n;

	public:



		data()
		{
			
		}
		data(string ip, int n)
		{
			this->ip = ip;
			this->n = n;

		}


		string getIp() const { return ip; }
		void setIp(int ip) { this->ip = ip; }
		int getN() const { return n; }
		void setN(int n) { this->n = n; }

		friend ostream& operator<<(ostream &out, const data &p)
		{
			out << p.getIp() << " " << p.getN() << " ";
			return out;
		}

		friend bool operator<(const data &left, const data &right)
		{


			if (left.n < right.n)
				return true;
			else if (left.n > right.n)
				return false;
			else
				return left.ip > right.ip;
		}


		~data()
		{
		}
	};
}